package geektime.spring.autoconfiguredemo.controller;


import geektime.spring.autoconfiguredemo.service.UserService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Controller;

import javax.annotation.Resource;

@Slf4j
@Controller("userControllerA")
public class UserController {
    @Resource(name="userServiceA")
    private UserService userService;
    public void save(){
        this.userService.save();
        log.info("UserController.....save() :{}","测试成功");
    }
    public void setUserService(UserService userService){
        this.userService = userService;
    }
}

